public class Test2 {
    public static void main(String[] args) {
        IList mySingleList = new MySingleList();
        mySingleList.addFirst(12);
        mySingleList.addFirst(23);
        mySingleList.addFirst(34);
        mySingleList.addFirst(45);
        mySingleList.addLast(1);
        mySingleList.addLast(2);
        mySingleList.addLast(3);

        try {
            mySingleList.addIndex(99,99);
        }catch (IndexOutOfBoundsException e) {
            e.printStackTrace();
        }
        mySingleList.display();
    }
}
